<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>


<title>POS收单运营管理平台</title>

<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<link href="<s:url value="/css/common.less"/>" type="text/less"
	rel="stylesheet" />
<link href="<s:url value="/css/common.css"/>" type="text/css"
	rel="stylesheet" />

<script type="text/javascript"
	src="<s:url value="/js/jquery-1.3.2.js" />"></script>
<script type="text/javascript"
	src="<s:url value="/js/jquery-1.9.1.js" />"></script>
<script type="text/javascript"
	src="<s:url value="/js/jquery.blockUI.js" />"></script>
<script type="text/javascript"
	src="<s:url value="/js/jquery.validate.min.js" />"></script>
<script type="text/javascript"
	src="<s:url value="/js/pwms.validate.js?v13" />"></script>
<script language="javascript" type="text/javascript"
	src="<s:url value="/js/My97DatePicker/WdatePicker.js"/>"></script>

<style type="text/css">
.error {
	color: red;
}
</style>
<script type="text/javascript">
	function registerOrderProcess(){
		var merchantNo = $.trim($("#merchantNo").val());
		var accountNo = $.trim($("#accountNo").val());
		var systemNo = $.trim($("#systemNo").val());
		var transAmt = $.trim($("#transAmt").val());
		
		var transDate = $.trim($("#transDate").val());
		if(!merchantNo){
			alert("商户号为空");
			return false;
		}
		
		if(!accountNo){
			alert("交易账号为空");
			return false;
		}
		
		if(!systemNo){
			alert("系统参考号为空");
			return false;
		}
		
		if(!transAmt){
			alert("交易金额为空");
			return false;
		}
		
		if(!(/^\d+(\.{0,1}\d+){0,1}$/.test(transAmt) )){
        	alert("请正确输入数字，只能为非负数字");
    		return false;
        }
		
		if(transAmt.lastIndexOf(".") != -1 && transAmt.substring(transAmt.indexOf(".")+1).length >2){
        	alert("交易金额最多只能保留两位小数");
        	return false;
        }
		
		if(!transDate){
			alert("清算/交易 日期为空");
			return false;
		}
		$("#btnAdd").attr("disabled",true);
		$("#registerRiskOrder").submit();
		
		
	}
	

</script>



</head>

<body>
	<s:form id="registerRiskOrder" action="/orpro/registerOrderProcess.ct" method="post"
		theme="simple">
		<table width="100%" class="tb">
			<tr class="tb-line">
				<td class="tb-td" colspan="6">
					<div class="tb-h2">POS收单运营管理平台</div>
				</td>
			</tr>
			<tr class="tb-line bg-gray">
				<td class="tb-td" colspan="4">
					<div class="tb-h3">差错登记</div>
				</td>
			</tr>
			<tr class="tb-line">
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">商户号：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> <s:textfield
							id="merchantNo" maxLength="200" name="rso.merchantNo" cssClass="queryWidth"></s:textfield>
				</label> <font color="red">*</font></td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">交易账号：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> <s:textfield
							id="accountNo" maxLength="200" name="rso.accountNo" cssClass="queryWidth"></s:textfield>
				</label> <font color="red">*</font></td>
			</tr>
			
			<tr class="tb-line">
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">系统参考号：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> <s:textfield
							id="systemNo" maxLength="200" name="rso.systemNo" cssClass="queryWidth"></s:textfield>
				</label> <font color="red">*</font></td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">交易金额：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> <s:textfield
							maxLength="200" name="rso.transAmt" cssClass="queryWidth"
							id="transAmt"></s:textfield>
				</label> <font color="red">(单位元)</font></td>
			</tr>
			
			<tr class="tb-line">
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">清算/交易 日期：</div>
				</td>
				<td class="tb-td">
				<label class="tb-input-mini"><s:textfield id="transDate"  name="rso.transDate" 
                onfocus="WdatePicker({dateFmt:'yyyyMMdd',readOnly:true,wdate:true,errDealMode:0});"
                /></label><font color="red">*</font></td>
                
                <td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">查询：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="firstQuery" name="rso.firstQuery"/> --%>
					<s:select id="firstQuery" name="rso.firstQuery" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label></td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">二次查询：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="secondQuery" name="rso.secondQuery"/> --%>
					<s:select id="secondQuery" name="rso.secondQuery" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">调单：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="firstSurvey" name="rso.firstSurvey"/> --%>
					<s:select id="firstSurvey" name="rso.firstSurvey" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label></td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">二次调单：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="secondSurvey" name="rso.secondSurvey"/> --%>
					<s:select id="secondSurvey" name="rso.secondSurvey" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">贷记调整：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="loanAdjust" name="rso.loanAdjust"/> --%>
					<s:select id="loanAdjust" name="rso.loanAdjust" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">请款：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="firstWithdrawCash" name="rso.firstWithdrawCash"/> --%>
					<s:select id="firstWithdrawCash" name="rso.firstWithdrawCash" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">退单：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="firstChargeBack" name="rso.firstChargeBack"/> --%>
					<s:select id="firstChargeBack" name="rso.firstChargeBack" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">二次请款：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="secondWithDrawCash" name="rso.secondWithDrawCash"/> --%>
					<s:select id="secondWithDrawCash" name="rso.secondWithDrawCash" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">二次退单：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="secondChargeBack" name="rso.secondChargeBack"/> --%>
					<s:select id="secondChargeBack" name="rso.secondChargeBack" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">例外协商：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="exceptionNegotiate" name="rso.exceptionNegotiate"/> --%>
					<s:select id="exceptionNegotiate" name="rso.exceptionNegotiate" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">例外长款：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="exceptionLongMoney" name="rso.exceptionLongMoney"/> --%>
					<s:select id="exceptionLongMoney" name="rso.exceptionLongMoney" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
			</tr>
			
			<tr class="tb-line">
				
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">托收请款：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen">
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="collectionWithDrawCash" name="rso.collectionWithDrawCash"/> --%>
					<s:select id="collectionWithDrawCash" name="rso.collectionWithDrawCash" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
				
				<td align="right" class="tb-td" style="width: 110px;">
					<div class="tb-h4" id="title">托收协商：</div>
				</td>
				<td class="tb-td"><label class="tb-input-lengthen"> 
					<%-- <s:select list="#{0:'否',1:'是'}" listKey="key" listValue="value" id="collectionNegotiate" name="rso.collectionNegotiate"/> --%>
					<s:select id="collectionNegotiate" name="rso.collectionNegotiate" cssClass="queryWidth" list="#request.reasonCdMap" listKey="key" listValue="value" headerKey="" headerValue="否"></s:select>
				</label> </td>
			</tr>
			
		</table>
		<table width="100%" border="0" cellspacing="0" class="table">
			
			<tr class="tb-line">
				<td class="tb-td line-submit" align="center" colspan="4"><label
					class="tb-input-submit"> <input id="btnAdd" value="保  存" onclick="registerOrderProcess()" type="button"/>
				</label> <label class="tb-input-submit"> <input type="reset"
						value="取  消" />
				</label> <label class="tb-input-submit"> <input type="button"
						value="返回" onclick="history.back()" />
				</label></td>
			</tr>
		</table>
	</s:form>
</body>
</html>
